package com.shensi.common.core.enums;

public enum PayTypeEnum {
    //des里的空格是方便小票打印排版
    dzk("dzk", "电子卡  "),
    pos("pos", "pos机   "),
    wx("wx", "微信支付"),
    xj("xj", "现金    "),
    zfb("zfb", "支付宝  "),
    yhk("yhk", "银行卡  "),
    yzf("yzf", "预支付  "),
    zkbzf("yzf", "卡包支付"),
    def("", ""),
    cdk("cdk", "车队卡  "),
    dkq("dkq", "实体卡  "),

    ;

    private String type;
    private String des;

    PayTypeEnum(String type, String des) {
        this.type = type;
        this.des = des;
    }

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public String getDes() {
        return des;
    }

    public void setDes(String des) {
        this.des = des;
    }

    public static PayTypeEnum getByType(String type) {
        for (PayTypeEnum value : values()) {
            if (value.getType().equals(type)) {
                return value;
            }

        }
        return PayTypeEnum.def;
    }

}
